clear

*global folder "~/"

*cd "$folder"

use "$folder\InterestGroupsCentralBankCreditPolicies_data.dta"

xtset id year



*Table 1: Interest groups and central bank lending to governments

*(1)
cloglog CBGovtCreditSurvival Military t t2 t3, vce(cl id)
estimates store GovcloglogMil1

*(2)
cloglog CBGovtCreditSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store GovcloglogMil2

*(3)
cloglog CBGovtCreditSurvival Business t t2 t3, vce(cl id)
estimates store GovcloglogLib1

*(4)
cloglog CBGovtCreditSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store GovcloglogLib2

*(5)
cloglog CBGovtCreditSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Independent == 1, vce(cl id)
estimates store GovcloglogMil3
test

*(6)
cloglog CBGovtCreditSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Euro == 1, vce(cl id)
estimates store GovcloglogMil4
test


*Table 2: Interest groups and central bank discounting

*(1)
cloglog CBDiscountSurvival Military t t2 t3, vce(cl id)
estimates store PrivcloglogMil1

*(2)
cloglog CBDiscountSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store PrivcloglogMil2
test

*(3)
cloglog CBDiscountSurvival Business t t2 t3, vce(cl id)
estimates store PrivcloglogLib1

*(4)
cloglog CBDiscountSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store PrivcloglogLib2

*(5)
cloglog CBDiscountSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Independent == 1, vce(cl id)
estimates store PrivcloglogLib3

*(6)
cloglog CBDiscountSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Euro == 1, vce(cl id)
estimates store PrivcloglogLib4
test



*Figure 3: Hazard functions
cloglog CBDiscountSurvival Business t t2 t3, vce(cl id)
predict h0 if Business ==0, p
predict h1 if Business ==1, p
sort year
by year: egen LibHaz0 = mean(h0)
by year: egen LibHaz1 = mean(h1)

sort id year
cloglog CBDiscountSurvival Military t t2 t3, vce(cl id) eform
predict m0 if Military ==0, p
predict m1 if Military ==1, p
sort year
by year: egen MilHaz0 = mean(m0)
by year: egen MilHaz1 = mean(m1)

sort id year
cloglog CBGovtCreditSurvival Business t t2 t3, vce(cl id) eform
predict h00 if Business ==0, p
predict h11 if Business ==1, p
sort year
by year: egen LibHaz00 = mean(h00)
by year: egen LibHaz11 = mean(h11)

sort id year
cloglog CBGovtCreditSurvival Military t t2 t3, vce(cl id) eform
predict m00 if Military ==0, p
predict m11 if Military ==1, p
sort year
by year: egen MilHaz00 = mean(m00)
by year: egen MilHaz11 = mean(m11)


***************
*Online Apendix
***************

*Table A1: Summary statistics
cloglog CBGovtCreditSurvival Military t t2 t3, vce(cl id)
gen sampleMil = e(sample)

cloglog CBDiscountSurvival Business t t2 t3, vce(cl id)
gen sampleBus = e(sample)

sum CBGovtCreditSurvival CBDiscountSurvival Military Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis if sampleMil ==1 | sampleBus == 1



*Table A2: Interest groups and central bank lending to governments

*(1)
cloglog CBGovtCreditSurvival Military t t2 t3, vce(cl id)
estimates store GovcloglogMil1

*(2)
cloglog CBGovtCreditSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store GovcloglogMil2

*(3)
cloglog CBGovtCreditSurvival Business t t2 t3, vce(cl id)
estimates store GovcloglogLib1

*(4)
cloglog CBGovtCreditSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store GovcloglogLib2

*(5)
cloglog CBGovtCreditSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Independent == 1, vce(cl id)
estimates store GovcloglogMil3


*(6)
cloglog CBGovtCreditSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Euro == 1, vce(cl id)
estimates store GovcloglogMil4
test


*Table A3: Interest groups and central bank discounting

*(1)
cloglog CBDiscountSurvival Military t t2 t3, vce(cl id)
estimates store PrivcloglogMil1

*(2)
cloglog CBDiscountSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store PrivcloglogMil2
test

*(3)
cloglog CBDiscountSurvival Business t t2 t3, vce(cl id)
estimates store PrivcloglogLib1

*(4)
cloglog CBDiscountSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store PrivcloglogLib2

*(5)
cloglog CBDiscountSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Independent == 1, vce(cl id)
estimates store PrivcloglogLib3
test

*(6)
cloglog CBDiscountSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Euro == 1, vce(cl id)
estimates store PrivcloglogLib4






*********************
*Other support groups
*********************
egen Aristocratic = rowtotal(v2regsupgroups_0), missing
egen Agrarian =  rowtotal(v2regsupgroups_1), missing
egen PartyElites =  rowtotal(v2regsupgroups_2), missing
egen Religious =  rowtotal(v2regsupgroups_7), missing
egen LocalElites =  rowtotal(v2regsupgroups_8), missing
egen UrbanMiddleClass =  rowtotal(v2regsupgroups_10), missing
egen RuralMiddleClass =  rowtotal(v2regsupgroups_12), missing
egen ForeignGovernment =  rowtotal(v2regsupgroups_13), missing


*Table A4: Other interest groups and central bank lending to governments

cloglog CBGovtCreditSurvival Aristocratic t t2 t3, vce(cl id)
estimates store GovtAristo1

cloglog CBGovtCreditSurvival Agrarian t t2 t3, vce(cl id)
estimates store GovtAgrarian1

cloglog CBGovtCreditSurvival PartyElites t t2 t3, vce(cl id)
estimates store GovtParty1

cloglog CBGovtCreditSurvival Religious t t2 t3, vce(cl id)
estimates store GovtReligious1

cloglog CBGovtCreditSurvival LocalElites t t2 t3, vce(cl id)
estimates store GovtLocal1

cloglog CBGovtCreditSurvival UrbanMiddleClass t t2 t3, vce(cl id)
estimates store GovtMiddle1

cloglog CBGovtCreditSurvival RuralMiddleClass t t2 t3, vce(cl id)
estimates store GovtRural1

cloglog CBGovtCreditSurvival ForeignGovernment t t2 t3, vce(cl id)
estimates store GovtForeign1



*Table A5: Other interest groups and central bank discounting

cloglog CBDiscountSurvival Aristocratic t t2 t3, vce(cl id)
estimates store DiscAristo1

cloglog CBDiscountSurvival Agrarian t t2 t3, vce(cl id)
estimates store DiscAgrarian1

cloglog CBDiscountSurvival PartyElites t t2 t3, vce(cl id)
estimates store DiscParty1

cloglog CBDiscountSurvival Religious t t2 t3, vce(cl id)
estimates store DiscReligious1

cloglog CBDiscountSurvival LocalElites t t2 t3, vce(cl id)
estimates store DiscLocal1

cloglog CBDiscountSurvival UrbanMiddleClass t t2 t3, vce(cl id)
estimates store DiscMiddle1

cloglog CBDiscountSurvival RuralMiddleClass t t2 t3, vce(cl id)
estimates store DiscRural1

cloglog CBDiscountSurvival ForeignGovernment t t2 t3, vce(cl id)
estimates store DiscForeign1


*Table A6: Interest groups and central bank lending to governments, logit


*(1)
logit CBGovtCreditSurvival Military t t2 t3, vce(cl id)
estimates store GovlogitMil1

*(2)
logit CBGovtCreditSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store GovlogitMil2
test

*(3)
logit CBGovtCreditSurvival Business t t2 t3, vce(cl id)
estimates store GovlogitBus1
test

*(4)
logit CBGovtCreditSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store GovlogitBus2
test

*(5)
logit CBGovtCreditSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Independent == 1, vce(cl id)
estimates store GovlogitMil3

*(6)
logit CBGovtCreditSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Euro == 1, vce(cl id)
estimates store GovlogitMil4
test


*Table A7: Interest groups and central bank discounting, logit

*(1)
logit CBDiscountSurvival Military t t2 t3, vce(cl id)
estimates store PrivlogitMil1

*(2)
logit CBDiscountSurvival Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store PrivlogitMil2

*(3)
logit CBDiscountSurvival Business t t2 t3, vce(cl id)
estimates store PrivlogitBus1

*(4)
logit CBDiscountSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, vce(cl id)
estimates store PrivlogitBus2

*(5)
logit CBDiscountSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Independent == 1, vce(cl id)
estimates store PrivlogitBus3

*(6)
logit CBDiscountSurvival Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3 if Euro == 1, vce(cl id)
estimates store PrivlogitBus4


*Table A8: Interest groups and central bank credit policies, instrumental variables

*Construct instruments
sort year
by year: egen SumWorldInterNatWar = sum(InterNatWar)

*to match the scale of uk interest rates, I divide this by 4.
replace SumWorldInterNatWar = SumWorldInterNatWar/4

sort id year
by id: gen RollingIntconflict = sum(InterNatWar)
by id: gen CounterAfter1788 = _n - 389 if year>= 1789
gen IntWarFractionYears = RollingIntconflict / CounterAfter1788
gen SumWorldInterNatWarOtherThan = SumWorldInterNatWar - InterNatWar
gen BartikMil = SumWorldInterNatWarOtherThan * IntWarFractionYears

by id: gen RollingBusiness = sum(Business)
gen BusinessFractionYears = RollingBusiness / CounterAfter1788
gen BartikBus = LongTermBondRateUK * BusinessFractionYears


xtset id year

*(1)
reg Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis BartikMil t t2 t3 if CBGovtCreditSurvival !=.
estimates store IVMil1First

*(2)
ivcloglog CBGovtCreditSurvival InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, aux(Military  = BartikMil) endo(Military) vce(cl id) vhatname(vhat1) nogen show
estimates store IVMil1

*(3)
reg Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis BartikBus t t2 t3 if CBGovtCreditSurvival !=.
estimates store IVBus1First

*(4)
ivcloglog CBGovtCreditSurvival InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, aux(Business  = BartikBus) endo(Business) vce(cl id) vhatname(vhat3) nogen show
estimates store IVBus1 

*(5)
reg Military InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis BartikMil t t2 t3 if CBDiscountSurvival !=.
estimates store IVMil2First

*(6)
ivcloglog CBDiscountSurvival InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, aux(Military = BartikMil) endo(Military) vce(cl id) vhatname(vhat2) nogen show
estimates store IVMil2

*(7)
reg Business InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis BartikBus t t2 t3 if CBDiscountSurvival !=.
estimates store IVBus2First

*(8)
ivcloglog CBDiscountSurvival InterNatWar LegislativeConst FiscalCapacity lnGDPPerCap externaldefault inflationcrises systemiccrisis t t2 t3, aux(Business  = BartikBus) endo(Business) vce(cl id) vhatname(vhat4) nogen show
estimates store IVBus2


*Table A9: Interest groups and central bank credit policies, ARDL error correction form

*(1)
reg d.CBGovtCredit l.CBGovtCredit d.Military l.Military, vce(cl id)
estimates store ErrorCorrGovMil

*(2)
reg d.CBGovtCredit l.CBGovtCredit d.Business l.Business, vce(cl id)
estimates store ErrorCorrGovBus

*(3)
reg d.CBDiscount l.CBDiscount d.Business l.Business, vce(cl id)
estimates store ErrorCorrDiscBus

*(4)
reg d.CBDiscount l.CBDiscount d.Military  l.Military , vce(cl id)
estimates store ErrorCorrDiscMil


